package com.lanou.timeline.classification.controller;

import com.lanou.timeline.classification.entity.TimelineClassification;
import com.lanou.timeline.classification.service.impl.TimelineClassificationServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/timelineclassification")
public class TimelineClassificationController {
    @Autowired
    private TimelineClassificationServiceImpl timelineClassificationServiceImpl;

    /**
     * 展示所有的碎片分类
     */
    @GetMapping("/tag")
    public List<TimelineClassification> showAllTag(){
        List<TimelineClassification> timelineClassifications = timelineClassificationServiceImpl.showAllTag();
        return timelineClassifications;
    }


}
